package org.xhy.quickstarter.config;

import org.springframework.stereotype.Component;
import org.springframework.web.servlet.config.annotation.InterceptorRegistry;
import org.springframework.web.servlet.config.annotation.WebMvcConfigurer;
import org.xhy.quickstarter.interceptor.Interceptor;

/**
 * @description:
 * @Author: Xhy
 * @CreateTime: 2023-11-13 13:43
 */
@Component
public class WebMvcConfig implements WebMvcConfigurer {
    @Override
    public void addInterceptors(InterceptorRegistry registry) {
        registry.addInterceptor(new Interceptor())
        .addPathPatterns("/authorize/permission/**","/authorize/role/**");
    }
}
